package springsecurity.utlis;

import java.util.Arrays;
import java.util.Collections;
import java.util.List;

/**
 * Created with IntelliJ IDEA.
 *
 * @User: c.c
 * @Date: 2022/6/14
 * @Time: 11:46
 * @Description: 登录豁免 以及 需要登录才能访问的
 */

public final class Statements {
    /**
     * 权限豁免地址列表() 不需登录直接访问
     */
    private static final List<String> IGNORE_URL = Arrays.asList("/pass/**","/login","/login.html");

    /**
     * @author: C.c
     * @date: 2022-06-14 11:54
     * @description: 需要登录才能访问
    **/
//    private static final List<String> LOGIN_SHARE_URLS = Collections.emptyList();
    private static final List<String> LOGIN_SHARE_URLS = Arrays.asList("/toMain","/toAuth","/main.html");


    public static List<String> getIgnoreURL() {
        return Collections.unmodifiableList(IGNORE_URL);
    }

    public static List<String> getLoginShareUrls() {
        return Collections.unmodifiableList(LOGIN_SHARE_URLS);
    }
}
